package com.shure.encrypt.encrypt;

import com.shure.encrypt.utils.EncryptUtils;
import org.springframework.stereotype.Service;

@Service("encryptService")
public class DefaultEncryptServiceImpl implements EncryptService {
    @Override
    public String encrypt(String data, String key) {
        return this.encrypt(data);
    }

    @Override
    public String encrypt(String data) {
        return EncryptUtils.encrypt(data);
    }

    @Override
    public String decrypt(String data, String key) {
        return this.decrypt(data);
    }

    @Override
    public String decrypt(String data) {
        return EncryptUtils.decrypt(data);
    }
}
